package com.ss.android.article.browser.lockscreen;

import android.content.Context;
import android.content.Intent;
import android.net.Uri;

import com.ss.android.lockscreen.e;

import java.io.File;

public class b implements a {
    private static e a;

    static {
        b.a = null;
    }

    public b() {

    }

    public static void a(Context arg3, String arg4) {
        if (arg4 != null && (arg4.endsWith(".apk"))) {
            Intent v0 = new Intent("android.intent.action.VIEW");
            v0.addCategory("android.intent.category.DEFAULT");
            v0.setDataAndType(Uri.fromFile(new File(arg4)), "application/vnd.android.package-archive");
            v0.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
            arg3.startActivity(v0);
        }
    }

    private static e b() {
        if (b.a == null) {
            Class v1 = b.class;
            synchronized (v1) {
                if (b.a == null) {
                    e v0_1 = e.a();
                    com.ss.android.lockscreen.bb.a().b = new com.ss.android.lockscreen.e.a();
                    com.ss.android.lockscreen.bb.a().c = new com.ss.android.lockscreen.e.e$e();
                    com.ss.android.lockscreen.bb.a().d = new  com.ss.android.lockscreen.e.e$c();
                    com.ss.android.lockscreen.bb.a().e = new com.ss.android.lockscreen.e.d();
                    com.ss.android.lockscreen.bb.a().f = new com.ss.android.lockscreen.e.e$b();
                    b.a = v0_1;
                }

            }
        }

        return b.a;
    }

    public final void a(Context arg1) {
        b.b();
        e.a(arg1);
        b.b();
        e.d();
    }

    public final void a(boolean arg1) {
        b.b();
        e.a(arg1);
    }

    public final boolean a() {
        b.b();
        return e.c();
    }
}

